[Logo: Substance Painter]

Substance Painter#

This plugin integrates Prism into Adobe Substance 3D Painter.

Overview#

This integration enables users to import geometry files into Substance Painter, save and version their scenefiles and export textures to the Prism project folder.

Setup#

This plugin can be installed using the Prism Hub like any other plugin.

When the plugin is loaded, the Prism integration needs to be added to the Substance Painter user settings folder.

In the Prism User Settings in the “DCC apps” -> “Substance Painter”, the integration can be added.
Alternatively it can also be added in the Prism installer or by using the setup.bat in the Prism install directory.
The integration should be added to the Substance Painter user preferences, which is here by default: %USERPROFILE%\Documents\Adobe\Adobe Substance 3D Painter.
This folder gets created when you launch Substance Painter for the first time.
Once this is done you can launch Substance Painter and in the “Python” menu click the “PrismInit” option.
This step is needed only once.
Now there is a menu with the Prism icon in the menu bar from where you can access the Prism tools.
../../_images/substancepainter_menu.jpg

Importing Geometry#

To import geometry from your Prism project into Substance Painter you can use the “Import Geometry” option from the Prism menu or rightclick a product version in the Project Browser and select “Import”.

../../_images/substancepainter_import.jpg

Saving Scenefiles#

You can save new scenefile versions using the options in the Prism menu or by opening the Project Browser and selecting “Create new version from current” in the context menu in the “Scenefiles” tab.

../../_images/substancepainter_saveVersions.jpg

Exporting Textures#

To export texture maps select the “Export Textures” option in the Prism menu.

This will open an export window where you can configure which maps to export.
You can also use export presets, which you can edit in the native Substance Painter Output Template window.
../../_images/substancepainter_exportTextures.jpg
The exported textures are then visible in the “Libraries” tab in the Project Browser.
To see this tab make sure you have the Libraries Plugin installed.
../../_images/substancepainter_viewInLibraries.jpg

Adding Prism integration using environment variables#

It is possible to use environment variables to add the Prism integration to Substance Painter instead of adding the Prism integration into the Substance Painter User Preferences.

The following environment variables need to be defined:

PRISM_ROOT = C:\Program Files\Prism2
SUBSTANCE_PAINTER_PLUGINS_PATH = C:\ProgramData\Prism2\plugins\SubstancePainter\Integration

These environment variables can be set in the system settings.

To load the Prism Substance Painter plugin from a central location in your studio you can set the SUBSTANCE_PAINTER_PLUGINS_PATH environment variable and point it to a folder on your network storage.
In that folder create a plugins/PrismInit.py file with the following content:
import os
import sys

os.environ["PRISM_ROOT"] = "C:\\Program Files\\Prism2"


def start_plugin():
    prismInit()


def close_plugin():
    global pcore
    if pcore.appPlugin:
        pcore.appPlugin.unregister()


def prismInit():
    prismRoot = os.getenv("PRISM_ROOT")
    scriptDir = os.path.join(prismRoot, "Scripts")

    if scriptDir not in sys.path:
        sys.path.append(scriptDir)

    import PrismCore
    import importlib
    importlib.reload(PrismCore)
    global pcore
    pcore = PrismCore.PrismCore(app="SubstancePainter")
    return pcore